<template>
  <div class="list">
    <div class="title">品牌制造商直供</div>
    <ul>
      <li v-for="item in brandList" :key="item.id" @click="goBrand(item)">
        <img :src="item.pic_url" width="100%" style="display: block" alt="" />
        <h4>{{ item.name }}</h4>
        <p>{{ item.floor_price | filtermoney }}</p>
      </li>
    </ul>
  </div>
</template>

<script>
export default {
  name: "MyList",
  props: ["brandList"],
  methods: {
    goBrand(item) {
      this.$router.push('/Brand/'+item.id);
    },
  },
};
</script>



<style lang="less" scoped>
.list {
  background: #fff;
  margin-top: 20px;
  margin-bottom: 20px;
}
.title {
  text-align: center;
  height: 50px;
  line-height: 50px;
  font-size: 0.2rem;
}
ul {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  li {
    width: 49%;
    margin-bottom: 2px;
    position: relative;
    h4 {
      position: absolute;
      left: 0.1rem;
      top: 10px;
      font-weight: normal;
    }
    p {
      position: absolute;
      left: 0.1rem;
      top: 40px;
      color: darkred;
    }
  }
}
</style>